package cn.gengms.chat;

import ch.qos.logback.classic.Level;
import ch.qos.logback.classic.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.web.socket.config.annotation.EnableWebSocket;

import javax.annotation.PostConstruct;

@SpringBootApplication
@EnableWebSocket
public class ChatApplication {
    public static Logger errorLogger = (Logger) LoggerFactory.getLogger("cn.gengms.error");
    public static void main(String[] args) {
        SpringApplication.run(ChatApplication.class, args);
    }
    @PostConstruct
    public void setLogger(){
        errorLogger.setLevel(Level.ERROR);
    }
}
